<?php
/*
===========================================================================

  Copyright (c) 2010-2012 DSPWeb Development Team

  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 3 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program.  If not, see http://www.gnu.org/licenses/

  This file is part of DSPWeb source code

===========================================================================
*/

if (!empty($error)) {
$output .= '
<table cellpadding=0 cellspacing=0 width="45%" border="0" style="border: 1px solid #F00; border-radius: 5px; background-color: #FFA8A8; color: #F00; font-family: Verdana; font-size: 12px;">
  <tr>
    <td style="border-right: 1px solid #F00; padding: 5px; font-weight: bold; font-size: 16px; text-align: center;">!</td>
    <td style="padding: 5px; vertical-align: middle; text-align: center;">'.$error.'</td>
  </tr>
</table></center>';
}
if (!empty($success)) {
$output .= '
<center>
<table cellpadding=0 cellspacing=0 width="45%" border="0" style="border: 1px solid #06F; border-radius: 5px; background-color: #0CF; color: #06F; font-family: Verdana; font-size: 12px;">
  <tr>
    <td style="border-right: 1px solid #060; padding: 5px; font-weight: bold; font-size: 16px; text-align: center;">!</td>
    <td style="padding: 5px; vertical-align: middle; text-align: center;">Password changed successfully</td>
  </tr>
</table></center>';
}
$output .= '
<form method="post" action="account.php">
<br />
<center><table width="85%" border="0" style="border: 1px solid #c0c0c0;" cellpadding=0 cellspacing=0>
  <tr>
    <td style="background-color: #f1f3f5; border-bottom: 1px solid #c0c0c0; padding: 5px; font-weight: bold; font-size: 12px; color: #3f6fbc;">Account Management</td>
  </tr>
  <tr>
    <td style="padding: 10px;"><center><table border="0" style="border: 1px solid #C0c0c0; background-color: #F1F3F5; padding: 5px;">
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Username:</td>
        <td style=" vertical-align: middle;"><span style="font-size: 12px;">'.$_SESSION['login'].'</span></td>
      </tr>
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Account Type:</td>
        <td><span style="font-size: 12px;"><em>'.getAccountType(getAccountID($_SESSION['login'])).'</em></span></td>
      </tr>
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Password:</td>
        <td><input type="password" name="password" style="border: 1px solid #c0c0c0; background-color: #fff; font-family: Verdana; font-size: 12px; padding: 2px;"></td>
      </tr>
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Confirm Password:</td>
        <td><input type="password" name="confpass" style="border: 1px solid #c0c0c0; background-color: #fff; font-family: Verdana; font-size: 12px; padding: 2px;"></td>
      </tr>
      <tr>
        <td colspan=2 style="text-align: center;"><input type="hidden" name="updateacc" value="1"><input type="submit" value="Update" style="border: 1px solid #c0c0c0; background-color: #f1f3f5;"><input type="button" value="Reset" style="border: 1px solid #c0c0c0; background-color: #f1f3f5;"></form></td>
      </tr>
    </table></center></td>
  </tr>
</table></center>';
?>